<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>文件下载</title>
    <link th:href="@{/login/css/bootstrap1.css}" rel="stylesheet">
    <script th:src="@{/login/js/bootstrap1.js}"></script>
    <script th:src="@{/login/js/jquery.js}"></script>
</head>
<body>
<div style="margin-bottom: 10px">文件下载列表：</div>
<table>
    <tr>
        <form action="/downLoadFile" method="post" enctype="multipart/form-data">
            <input type="file" name="fileUpload" required>
            <button type="submit">上传</button>
        </form>
        <!--若文件不存在则不显示-->
        <td><a th:if="${fileName}" th:href="@{/download(filename=${fileName})}">下载文件</a></td>
    </tr>
</table>
</body>
</html>